<template>
    <div class="page-bg">
        <com-header />
        <div class="content df mt-20">
            <div class="left fc">
                <goods-info :data="data" />
                <goods-detail :data="data" class="mt-20" />
            </div>
            <div class="right">
                <goods-developinfo :data="data"></goods-developinfo>
            </div>
        </div>
    </div>
</template>

<script>
import comHeader from "@/components/com-header.vue";
import goodsInfo from "@/components/goods-info.vue";
import goodsDetail from "@/components/goods-describe.vue";
import goodsDevelopinfo from "@/components/goods-developinfo.vue";

import myAxios from "@/utils/index";

export default {
    components: { comHeader, goodsInfo, goodsDetail, goodsDevelopinfo},
    data(){
        return {
            id: 0,
            data: null,
        }
    },
    created(){
        this.id = this.$route.params.id;
        this.getData();
    },
    methods:{
        getData(){
            // this.id = 69;
            myAxios.get("/ddd-order/goods/"+this.id).then(res=>{
                if(!res?.data){return}
                this.data = res.data;
            });
        }
    }
}
</script>

<style scoped>
.content{width:1200px; margin-left:auto; margin-right:auto;}
.right{width:224px; margin-left:20px;}
</style>
